import request from '../utlis/request'

// 获取用户列表
// export function UserList(queryInfo){
//     request.get('users',{params:queryInfo})
// } 

export const UserList = (queryInfo)=>{
    return request.get('users',{params:queryInfo})
}


//修改用户开关接口
export const changeUserState = (userinfo)=>{
    return request.put(`users/${userinfo.id}/state/${userinfo.mg_state}`)
}

//添加用户接口
export const ReqaddUser = (addForm)=>{
    return request.post('users',addForm)
}

//获取编辑用户的接口
export const ReqEditUser = (id)=>{
    return request.get('users/' + id)
}